package edu.sctu.wulixia.month6.day20150606.Check;

import edu.sctu.wulixia.month6.day20150606.PeopleInfo.PeopleAppbean;

/**
 * Created by user05 on 2015/6/6.
 */

//进地铁站安检

public class SecurityCheck {
    private PeopleAppbean peopleappbean;
    private String weijin;

    public SecurityCheck(PeopleAppbean peopleappbean,String weijin){
        this.peopleappbean = peopleappbean;
        this.weijin = weijin;
    }


    public boolean checkBackPack(){
        boolean is_weijin = false;
        if(peopleappbean.isBackpack()){
            if(weijin.equals(peopleappbean.getBackpackName())){
                is_weijin = true;
            }
        }else{
            is_weijin = false;
        }
        return is_weijin;
    }



    public boolean checkWater(){
        boolean is_weijin = false;
        if(peopleappbean.isWater()){
            if(weijin.equals(peopleappbean.getWaterName())){
                is_weijin = true;
            }
        }else{
            is_weijin = false;
        }

        return is_weijin;
    }

}
